package miniBanco.Gui;

import java.awt.BorderLayout;
import java.util.ArrayList;

import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTable;
import miniBanco.Dto.Errores;
import miniBanco.Handler.HandlerErrores;

public class ErroresGrid extends JPanel {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private BorderLayout layout;
	private JTable table;
	public ErroresGrid(ArrayList<Errores> erroresList)
	{
		HandlerErrores.getInstance();
		
		//Seteo el layout
    	layout = new BorderLayout();
 		setLayout(layout);
		
 		ErroresTableModel model = new ErroresTableModel(erroresList);
		table = new JTable(model);
		JScrollPane scrollPane = new JScrollPane(table);
		table.setFillsViewportHeight(true);
		add(scrollPane,BorderLayout.CENTER);
	}

}


